#ifndef WIDGET_H
#define WIDGET_H

#include <QtGui>
#include <QtCore>
#include <QtXml>

namespace Ui
{
    class Widget;
}

class Widget : public QWidget
{
    Q_OBJECT

public:
    Widget(QWidget *parent = 0);
    ~Widget();

private:
    Ui::Widget *ui;
    QXmlStreamReader reader;
    QXmlStreamWriter writer;
    QMap<QString, QString> map;
    QString key;
    QDate date;

private slots:
    void on_calendarWidget_selectionChanged();
    void on_tableWidgetMonth_cellClicked (int row, int column );

private:
    bool buildMap();
    void save();
    void closeEvent(QCloseEvent *e);
};

#endif // WIDGET_H
